package com.yang.frost.blueberry.config.properties;

import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.boot.context.properties.NestedConfigurationProperty;
import org.springframework.stereotype.Component;

/**
 * @author 10296
 * @date 2021/1/25
 * @Description: 配置文件
 */
@Component
@ConfigurationProperties(prefix = "blueberry")
public class BlueBerryProperties {

    /**
     * 是否启用ansi控制台输出有颜色的字体，local环境建议开启，服务器环境设置为false
     */
    private boolean enableAnsi;

    /**
     * 是否启用验证码
     */
    private boolean enableVerifyCode;


    /**
     * Shiro配置
     */
    @NestedConfigurationProperty
    private ShiroProperties shiro = new ShiroProperties();


    public boolean isEnableAnsi() {
        return enableAnsi;
    }

    public void setEnableAnsi(boolean enableAnsi) {
        this.enableAnsi = enableAnsi;
    }

    public boolean isEnableVerifyCode() {
        return enableVerifyCode;
    }

    public void setEnableVerifyCode(boolean enableVerifyCode) {
        this.enableVerifyCode = enableVerifyCode;
    }

    public ShiroProperties getShiro() {
        return shiro;
    }

    public void setShiro(ShiroProperties shiro) {
        this.shiro = shiro;
    }
}
